package pool;

public abstract class AbstractPoolObject {

	protected boolean state = true;
	
	/**
	 * 清理对象数据
	 */
	public abstract void clean();
	
	/**
	 * 使用池对象
	 */
	public void used()
	{
		state = false;
	}
	
	/**
	 * 释放池对象
	 */
	public void released()
	{
		state = true;
	}
	
	/**
	 * 检查对象是否可用
	 * @return
	 */
	public boolean check()
	{
		return state;
	}
	
}
